﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="frm_ClientBackBillList.aspx.cs" Inherits="SaleSystem.Business.frm_ClientBackBillList" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>退货管理</title>
</head>
<body>
<form id="form1" runat="server">
    <div>
    <ext:PageManager runat="server" ID="PageManager1" />
    <ext:Toolbar runat="server" ID="toolbar1">
        <Items>
            <ext:Button runat="server" ID="bnSearch" Text="查询" Icon="Reload" Type="Submit" OnClick="bnSearch_Click" ></ext:Button>
            <ext:Button runat="server" ID="bnNew" Text="新增" Icon="Add"  ></ext:Button>           
        </Items>    
    </ext:Toolbar> 
    <ext:Form runat="server" ID="Form2" EnableBackgroundColor="true" ShowHeader="false" BodyPadding="10px" ShowBorder="false">
        <Rows>
            <ext:FormRow>
            <Items>
            <ext:TextBox runat="server" ID="tb_CBB_Code" Label="退货单号" Width="200px" TabIndex="1"></ext:TextBox>
            <ext:TextBox runat="server" ID="tb_SBill_Code" Label="销售单号" Width="200px" TabIndex="2"></ext:TextBox>                    
             </Items>
            </ext:FormRow>
            <ext:FormRow>
             <Items> 
            <ext:TextBox runat="server" ID="tb_SBill_Code2" Label="出库单号" Width="200px" TabIndex="3"></ext:TextBox>                    
            <ext:TextBox runat="server" ID="tb_Cust_Name" Label="客户" Width="200px" TabIndex="4"></ext:TextBox>
              </Items>
            </ext:FormRow>
                  <ext:FormRow>
             <Items>
                     <ext:DatePicker runat="server" ID="dp_CBB_Date1"  Label="退货日期>=" Width="200px" TabIndex="5"></ext:DatePicker>                    
                    <ext:DatePicker runat="server" ID="dp_CBB_Date2" Label="退货日期<=" Width="200px" TabIndex="6"></ext:DatePicker>             
                    </Items>
            </ext:FormRow> 
            <ext:FormRow>
             <Items>               
                    <ext:DropDownList runat="server" ID="ddl_CBB_Input"  Label="入库状态" Width="200px" TabIndex="7">
                        <ext:ListItem Text="-未选择-" Value="-1" Selected="true" />
                        <ext:ListItem Text="未入库" Value="0" />
                        <ext:ListItem Text="已入库" Value="1"  />
                    </ext:DropDownList>   
                    <ext:DropDownList runat="server" ID="ddl_CBB_State" Label="结算状态" Width="200px" TabIndex="8"   DataValueField="Id" DataTextField="Name"></ext:DropDownList>       
             </Items>
            </ext:FormRow> 
        </Rows>
    </ext:Form>
    <ext:Grid runat="server" ID="gv_List" EnableBackgroundColor="true" Title="退货单列表"   IsDatabasePaging="true" DataKeyNames="CBB_Id,CBB_Code" EnableRowNumber="true" onrowcommand="gv_List_RowCommand" AllowPaging="true" onpageindexchange="gv_List_PageIndexChange"  AutoHeight="true" OnPreRowDataBound="gv_List_PreRowDataBound">
    <Columns>
        <ext:BoundField ColumnID="CBB_Code" DataField="CBB_Code" DataTooltipField="CBB_Code" HeaderText="退货单号"    Width="100px" />
        <ext:BoundField ColumnID="SBill_Code" DataField="SBill_Code" DataTooltipField="SBill_Code" HeaderText="销售单号"   Width="100px"/>
        <ext:BoundField ColumnID="SBill_Code2" DataField="SBill_Code2" DataTooltipField="SBill_Code2" HeaderText="出库单号"   Width="100px"/>
        <ext:BoundField ColumnID="Cust_Name" DataField="Cust_Name" DataTooltipField="Cust_Name" HeaderText="客户名称"   Width="100px"/>
        <ext:BoundField ColumnID="CBB_Money" DataField="CBB_Money DataTooltipField="CBB_Money" HeaderText="退货金额"   Width="80px"/>             
        <ext:TemplateField HeaderText="退货日期" Width="80px">
                <ItemTemplate>                
                    <%# DateTime.Parse(DataBinder.Eval(Container.DataItem, "CBB_Date").ToString()).ToString("yyyy-MM-dd")%>
                </ItemTemplate>
            </ext:TemplateField>
        <ext:BoundField ColumnID="CBB_Reason" DataField="CBB_Reason" DataTooltipField="CBB_Reason" HeaderText="退货原因"   Width="100px"/>                
        <ext:BoundField ColumnID="SUser_Name" DataField="SUser_Name" DataTooltipField="SUser_Name" HeaderText="经办人" Width="80px"/>
         <ext:CheckBoxField DataTooltipField="CBB_Input" Width="60px" RenderAsStaticField="true"  DataField="CBB_Input" HeaderText="是否入库" />
         <ext:CheckBoxField DataTooltipField="CBB_State" Width="60px" RenderAsStaticField="true"  DataField="CBB_State" HeaderText="是否结算" />
        <ext:LinkButtonField ColumnID="edit" CommandName="edit"  Text="编辑" HeaderText="编辑" Width="60px" />           
        <ext:LinkButtonField ColumnID="delete" CommandName="Delete"  ConfirmIcon="Question"  ConfirmText="确认删除此信息？" Text="删除" HeaderText="删除" Width="60px"/>
    </Columns>
    </ext:Grid>
    </div>
    <ext:Window runat="server" ID="win_Content" Popup="false" EnableIFrame="true"  EnableConfirmOnClose="true" Title="新增退货单" IFrameUrl="about:blank" Target="Top" IsModal="true" Width="800px" Height="600px" EnableMaximize="true"></ext:Window>
    </form>
</body>
</html>
